﻿using System;
using System.Collections.Generic;

namespace YJ.Data.Interface
{
    public interface IAppLibraryButtons
    {
        /// <summary>
        /// 新增
        /// </summary>
        int Add(YJ.Data.Model.AppLibraryButtons model);

        /// <summary>
        /// 更新
        /// </summary>
        int Update(YJ.Data.Model.AppLibraryButtons model);

        /// <summary>
        /// 查询所有记录
        /// </summary>
        List<YJ.Data.Model.AppLibraryButtons> GetAll();

        /// <summary>
        /// 查询单条记录
        /// </summary>
        Model.AppLibraryButtons Get(Guid id);

        /// <summary>
        /// 删除
        /// </summary>
        int Delete(Guid id);

        /// <summary>
        /// 查询记录条数
        /// </summary>
        long GetCount();


        /// <summary>
        /// 得到一页数据
        /// </summary>
        /// <param name="pager"></param>
        /// <param name="query"></param>
        /// <param name="order"></param>
        /// <param name="size"></param>
        /// <param name="numbe"></param>
        /// <param name="title"></param>
        /// <returns></returns>
        List<YJ.Data.Model.AppLibraryButtons> GetPagerData(out string pager, string query = "", int size = 15, int number = 1, string title = "");

        /// <summary>
        /// 得到一页数据
        /// </summary>
        /// <param name="count"></param>
        /// <param name="query"></param>
        /// <param name="title"></param>
        /// <param name="order"></param>
        /// <returns></returns>
        List<YJ.Data.Model.AppLibraryButtons> GetPagerData(out long count, int size, int number, string title = "", string order = "");

        /// <summary>
        /// 得到最大编号
        /// </summary>
        /// <returns></returns>
        int GetMaxSort();
    }
}
